/*
 * 
 * 	Name: Allen Shultz
 * 	Date: 7/25/14
 * 	ICS314
 * 
 */

package iCal;

import java.io.File;
import java.io.FileWriter;
import java.io.BufferedWriter;
import java.io.PrintWriter;

import java.io.IOException;

public class TestEvent {
	
    String whenStart = "DTSTART:20140813";
    String whenStop = "DTEND:20140813";
	
	public static void main(String[] args) throws IOException {                
		try {
			
			File TestEvent = new File("TestEvent.ics");
                        
            FileWriter fileWriter = new FileWriter(TestEvent.getAbsoluteFile());
            BufferedWriter buffWriter = new BufferedWriter(fileWriter);
            PrintWriter printer = new PrintWriter(buffWriter);
                       
            
            printer.println("BEGIN:VCALENDAR");
            printer.println("BEGIN:VTIMEZONE");
            printer.println("TZID:Pacific/Honolulu");
            printer.println("BEGIN:STANDARD");
            printer.println("TZOFFSETFROM:-1000");
            printer.println("TZOFFSETTO:-1000");
            printer.println("TZNAME:HST");
            printer.println("END:STANDARD");
            printer.println("END:VTIMEZONE");
            printer.println("BEGIN:VEVENT");
            printer.println("DTSTART:20140813");
            printer.println("DTEND:20140813");
            printer.println("LOCATION: Hamilton Library");
            printer.println("SUMMARY:Test Event for ICS 314");
            printer.println("END:VEVENT");
            printer.println("END:VCALENDAR");
                        
            printer.close();
		}
		
		catch(IOException e) {
                        
		}
/*
		String content = "File Content";
		File file = new File("file.txt");
		FileWriter fw = new FileWriter(file.getAbsoluteFile());
		BufferedWriter bw = new BufferedWriter(fw);
		bw.write(content);
		bw.close();
		
*/
		
	}
	
}